{if $iCnt}
{str_replace text="`viewing_ifrom_ito_out_of_icnt_image`" iFrom="`$iFrom`" iTo="`$iTo`" iCnt="`$iCnt`" }
<br/><br/>
{/if}

{include file="$sRootPath/_blocks/pager_nav_button.html"}
<br />
<table style="width:100%;" cellspacing="5" cellpadding="5">
{foreach from=$aItems item=aItem key=iKey name=aitems}
<tr>
    <td style="text-align:left;vertical-align:middle;" class="border2">
        <table style="width:100%;">
        <tr>
            <td style="width:30%;text-align:center;">

                <div style="padding-bottom:8px;">
                    <img src="design/pic/spacer.gif" class="sqr" style="vertical-align:middle;" alt="" width="7" height="7" />
                    <span style="vertical-align:middle;"> <b>{if $aItem.allow == 1}{language text="pending_54"}{else}{language text="approved"}{/if}</b> </span>
                </div>

                {if !$aItem.allow}
                <a href="{url link='public.gallery.view' id=$aItem.id}">
                {img max_width="120" src="`$sGImageUrl`thumb/`$aItem.id`.jpg" src_def="design/pic/noimage_120.jpg" style="vertical-align:middle;" class="pic1" onmouseover="this.className='pic2';" onmouseout="this.className='pic1';"}
                </a>
                {else}
                {img max_width="120" src="`$sGImageUrl`thumb/`$aItem.id`.jpg" src_def="design/pic/noimage_120.jpg" style="vertical-align:middle;" class="pic1" onmouseover="this.className='pic2';" onmouseout="this.className='pic1';"}
                {/if}
            </td>
            <td style="width:70%;vertical-align:top;font-size:8pt;" class="color">
                <form method="post" action="{url link='current' id=$aItem.id}">
                <table style="width:100%;" cellspacing="2" cellpadding="4">
                <tr>
                    <td style="text-align:right;" class="color">{language text="title"}:</td>
                    <td class="border13">
                        <input type="text" name="val[title]" value="{$aItem.text}" size="30" onfocus="this.className='inputmain';" onblur="this.className='';" />
                    </td>
                </tr>
                <tr>
                    <td style="text-align:right;" class="color">{language text="image_category"}:</td>
                    <td class="border13">
                    	<select name="val[category]" style="width:150px;">
                    		<option value="">{language text='core.any'}</option>
                            {html_options options=$aCategories selected=$aItem.category}
                    	</select>
                    </td>
                </tr>
                <tr>
                    <td style="text-align:right;" class="color" nowrap="nowrap">{language text='Mod_Gallery.who_can_view'}:</td>
                    <td class="border13">
                    	<select name="val[who_view]">
                    		{html_options options=$aPrivacySettings selected=$aItem.who_view}
                    	</select>
                    </td>
                </tr>
                <tr>
                    <td style="text-align:right;" class="color">{language text="Mod_Tag.tags"}:</td>
                    <td class="border13">
                    	<input type="text" name="val[tags]" maxlength="80" size="30" onfocus="this.className='inputmain';" onblur="this.className='';" value="{$aItem.tags|escape}" maxlength="75" />
                    </td>
                </tr>
                <tr>
                    <td></td>
                    <td>
                        <input name="act[update]" type="submit" value=" {language text="update_image"} " style="cursor:pointer;" class="mainmenu6" onmouseover="this.className='mainmenu7';" onmouseout="this.className='mainmenu6';" />
                        <span style="padding-left:10px;vertical-align:middle;"> <a class="link_action" onclick="return sure('');" href="{url link='current' delete=$aItem.id}">[ {language text="delete"} ]</a> </span>

                    </td>
                </tr>
                </table>
                </form>
            </td>
        </tr>
        </table>
    </td>
</tr>
{foreachelse}
<tr>
    <td style="width:70%;vertical-align:top;text-align:center;font-size:12px;color:green;font-weight:bold;" class="color">{language text="you_have_not_added_any_pictures_yet"}</td>
</tr>
{/foreach}
<tr>
<td>
</td></tr>
</table>
{include file="$sRootPath/_blocks/pager_nav_button.html"}